using System;

namespace Microsoft.WowAddonStudio.Lua.RuntimeService.ShellHost
{
	/// <summary>
	/// System.EventArgs is the base class for classes containing event data.
	/// </summary>
	public class ProcessExitedEventArgs : EventArgs
	{

		/// <summary>
		/// Gets or sets the name of the process.
		/// </summary>
		/// <value>The name of the process.</value>
		public string ProcessName { get; private set; }


		/// <summary>
		/// Gets or sets the exit code.
		/// </summary>
		/// <value>The exit code.</value>
		public int ExitCode { get; private set; }


		/// <summary>
		/// Initializes a new instance of the <see cref="ProcessExitedEventArgs"/> class.
		/// </summary>
		/// <param name="exitCode">The exit code.</param>
		/// <param name="processName">Name of the process.</param>
		public ProcessExitedEventArgs(int exitCode, string processName)
		{
			ExitCode = exitCode;
			ProcessName = processName;
		}

		/// <summary>
		/// Returns a <see cref="System.String"/> that 
		/// represents the current <see cref="ProcessExitedEventArgs"/>.
		/// </summary>
		/// <returns></returns>
		public override string ToString()
		{
			return String.Concat("ProcessExitedEventArgs: ", ProcessName);
		}
	}
}